00001
00002
00003
00004
00005
00006
#ifndef ISWPLUGINMENU_H
00007
#define ISWPLUGINMENU_H
00008
00009
#ifdef SWSERVICES_EXPORTS
00010
#define SWSERVICES_API __declspec(dllexport)
00011
#else
00012 #define SWSERVICES_API __declspec(dllimport)
00013
#endif
00014
00015
#include "stdafx.h"
00016
#include "swmacros.h"
00017
00018
struct SWPluginServerStruct;
00019
00032 class SWSERVICES_API ISWPluginMenu
00033 {
00034
public:
00040 class ISWMenuContext
00041 {
00042
public:
00043 enum ISWMenuContextType
00044 {
00045 MENUROWCOLSTRUCT
00046 };
00047
00053
virtual ISWMenuContextType GetType() = 0;
00054 };
00055
00057 enum SWMenuType
00058 {
00059
00060 Undefined,
00061 AuxStat,
00062 UserList
00063 };
00064
00080 typedef void ( __cdecl *
SWMENUACTIONCALLBACK)(
SWPluginServerStruct* pThisServer,
ISWPluginMenu::SWMenuType menuType,
ISWPluginMenu::ISWMenuContext* pMenuContext);
00081
00083
virtual SWMenuType GetMenuType() = 0;
00084
virtual ISWMenuContext* GetMenuContext() = 0;
00085
00090 #define ISWPluginMenu_IsSeparator 1
00091
00095 #define ISWPluginMenu_IsDisabled 2
00096
00100 #define ISWPluginMenu_IsChecked 4
00101
00108
virtual SWRESULT AddMenuItem( std::wstring strItemName, SWMENUACTIONCALLBACK fnPtr,
unsigned int flags ) = 0;
00109
00110 virtual ~ISWPluginMenu() {}
00111 };
00112
00117 class SWSERVICES_API MenuRowColStruct :
public ISWPluginMenu::ISWMenuContext
00118 {
00119
public:
00120
00122 virtual ISWPluginMenu::ISWMenuContext::ISWMenuContextType GetType() {
return ISWPluginMenu::ISWMenuContext::MENUROWCOLSTRUCT; };
00123
00128 UINT uiRow;
00129
00134 UINT uiCol;
00135 };
00136
00137
#endif //ISWPLUGINMENU_H